package com.njtoyo.taxi.admin.aop;

import cn.hutool.core.exceptions.StatefulException;
import cn.hutool.core.util.StrUtil;
import cn.hutool.http.HttpStatus;

/**
 * @author mdf
 * @description: 全局异常处理
 */
public class YDException extends StatefulException {



    public YDException(String msg) {
        super(HttpStatus.HTTP_INTERNAL_ERROR, msg);
    }

    public YDException(String templatemsg, Object... params) {
        super(HttpStatus.HTTP_INTERNAL_ERROR, StrUtil.format(templatemsg, params));
    }


    public YDException(Throwable throwable) {
        super(HttpStatus.HTTP_INTERNAL_ERROR, throwable);
    }

    public YDException(String msg, Throwable throwable) {
        super(HttpStatus.HTTP_INTERNAL_ERROR, msg, throwable);
    }

    public YDException(int status, String msg) {
        super(status, msg);
    }

    public YDException(int status, Throwable throwable) {
        super(status, throwable);
    }

    public YDException(int status, String msg, Throwable throwable) {
        super(status, msg, throwable);
    }

    public YDException(String msg, int status, Throwable throwable) {
        super(status, msg, throwable);
    }

}
